package cn.shentianlan.controller;

import cn.shentianlan.domain.dto.TeacherCourseDTO;
import cn.shentianlan.domain.entity.TeacherCourse;
import cn.shentianlan.service.TeacherCourseService;
import cn.shentianlan.utils.Result;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @Author 陈俊源
 * @Description TODO
 * @Date 2021/5/4
 * @Version 1.0
 */
@RestController
@RequestMapping("/teacherCourse")
public class TeacherCourseController {

    @Autowired
    private TeacherCourseService teacherCourseService;

    @RequestMapping("/save")
    public Result save(TeacherCourseDTO teacherCourseDTO){
        Result result = teacherCourseService.save(teacherCourseDTO);
        return result;
    }

    @RequestMapping("/delete")
    public Result delete(TeacherCourseDTO teacherCourseDTO){
        Result result = teacherCourseService.delete(teacherCourseDTO);
        return result;
    }

}
